<template>
	<view class="content">
		<view class="title">{{content.title}}</view>
		<view class="detail">
			<rich-text :nodes="content.content"></rich-text>
			<view class="message">
				<u-empty v-if="!content.title" text="暂无合约内容" mode="message"></u-empty>
			</view>
		</view>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				id:null,
				content:{},
			}
		},
		onReady() {
			
		},
		onLoad(e) {
			this.id = e.id
			this.getDetail()
		},
		methods: {
			//获取详情
			getDetail(){
				this.$http({
					url:this.$api.notice_getinfo,
					method:'POST',
					hideLoading:false,
					data:{id:this.id},
					success:res=>{
						this.content = res.data
					},
					complete:e=>{
						uni.stopPullDownRefresh();
					}
				})
			}
		}
	}
</script>

<style lang="less" scoped>
	.content{
		padding: 30rpx;
		.title{
			font-size: 20px;
			font-weight: 600;
			color:#5c67ff;
			letter-spacing: 1px;
		}
		.detail{
			margin-top: 40rpx;
			color: #FFFFFF;
		}
		::v-deep img{
			max-width: 100%!important;
		}
	}
</style>
